package org.zjx.battle.entity;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.zjx.common.model.RouteProperties;
import org.zjx.team.ITeam;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class Battle {
    private ITeam team;
    private List<Enemy> enemies;
    private int rounds; //回合数
    private List<Integer> bloods; //血量列表
    private Map<String, RouteProperties> routePropertiesMap = new HashMap<>(); //成员情况

    public Battle(ITeam team,List<Enemy> enemies){
        this.team = team;
        this.enemies = enemies;
    }

    public void upData(List<Enemy> enemies){
        this.enemies = enemies;
    }

    public void upData(RouteProperties routeProperties){
        routePropertiesMap.put(routeProperties.getPlayerId(),routeProperties);
    }
}
